function get_data(callback) {
    $$.ajax({
        url: "/sys/open/logout",
        result: {
            $200: function (data) {
                callback(data);
            }
        }
    });
}
module.exports = {
    template: require("./tpl/head.htm"),
    data: function () {
        return {
            head: $$.localStore('userInfo')
        };
    },
    methods: {
        loginOut: function () {
            get_data(function (ret) {
                localStorage.clear();
                sessionStorage.clear();
                setTimeout(function () {
                    location.replace('/sys/open/login.html?url=' + location.href)
                }, 0);
            })
        }
    }
};